package com.chen.mappers;

import com.chen.domain.User;
import com.chen.dto.UserDto;
import org.mapstruct.Mapper;
import org.mapstruct.factory.Mappers;

import java.util.List;

/**
 * @Author: chen
 * @Date: 2021/4/29 2:53 PM
 * @Version 1.0
 */
@Mapper(componentModel = "spring")
public interface UserDtoMapper {

    UserDtoMapper INSTANCE = Mappers.getMapper(UserDtoMapper.class);

    UserDto convert2Dto(User source);

    User convert2Do(UserDto source);

    List<UserDto> convert2ListDto(List<User> source);

    List<UserDto> convert2ListDo(List<UserDto> source);


}
